Integrand size = 12, antiderivative size = 83 \[ \int (a+a \sec (e+f x))^m \, dx=\frac {\sqrt {2} \operatorname {AppellF1}\left (\frac {1}{2}+m,\frac {1}{2},1,\frac {3}{2}+m,\frac {1}{2} (1+\sec (e+f x)),1+\sec (e+f x)\right ) (a+a \sec (e+f x))^m \tan (e+f x)}{f (1+2 m) \sqrt {1-\sec (e+f x)}} \]
[Out]
Time = 0.07 (sec) , antiderivative size = 83, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.250, Rules used = {3864, 3863, 141} \[ \int (a+a \sec (e+f x))^m \, dx=\frac {\sqrt {2} \tan (e+f x) (a \sec (e+f x)+a)^m \operatorname {AppellF1}\left (m+\frac {1}{2},\frac {1}{2},1,m+\frac {3}{2},\frac {1}{2} (\sec (e+f x)+1),\sec (e+f x)+1\right )}{f (2 m+1) \sqrt {1-\sec (e+f x)}} \]
[In]
[Out]
Rule 141
Rule 3863
Rule 3864
Rubi steps \begin{align*} \text {integral}& = \left ((1+\sec (e+f x))^{-m} (a+a \sec (e+f x))^m\right ) \int (1+\sec (e+f x))^m \, dx \\ & = -\frac {\left ((1+\sec (e+f x))^{-\frac {1}{2}-m} (a+a \sec (e+f x))^m \tan (e+f x)\right ) \text {Subst}\left (\int \frac {(1+x)^{-\frac {1}{2}+m}}{\sqrt {1-x} x} \, dx,x,\sec (e+f x)\right )}{f \sqrt {1-\sec (e+f x)}} \\ & = \frac {\sqrt {2} \operatorname {AppellF1}\left (\frac {1}{2}+m,\frac {1}{2},1,\frac {3}{2}+m,\frac {1}{2} (1+\sec (e+f x)),1+\sec (e+f x)\right ) (a+a \sec (e+f x))^m \tan (e+f x)}{f (1+2 m) \sqrt {1-\sec (e+f x)}} \\ \end{align*}
Leaf count is larger than twice the leaf count of optimal. \(711\) vs. \(2(83)=166\).
Time = 7.36 (sec) , antiderivative size = 711, normalized size of antiderivative = 8.57 \[ \int (a+a \sec (e+f x))^m \, dx=\frac {30 \operatorname {AppellF1}\left (\frac {1}{2},m,1,\frac {3}{2},\tan ^2\left (\frac {1}{2} (e+f x)\right ),-\tan ^2\left (\frac {1}{2} (e+f x)\right )\right ) \cos ^2\left (\frac {1}{2} (e+f x)\right ) \cos (e+f x) (a (1+\sec (e+f x)))^m \sin (e+f x) \left (3 \operatorname {AppellF1}\left (\frac {1}{2},m,1,\frac {3}{2},\tan ^2\left (\frac {1}{2} (e+f x)\right ),-\tan ^2\left (\frac {1}{2} (e+f x)\right )\right )-2 \left (\operatorname {AppellF1}\left (\frac {3}{2},m,2,\frac {5}{2},\tan ^2\left (\frac {1}{2} (e+f x)\right ),-\tan ^2\left (\frac {1}{2} (e+f x)\right )\right )-m \operatorname {AppellF1}\left (\frac {3}{2},1+m,1,\frac {5}{2},\tan ^2\left (\frac {1}{2} (e+f x)\right ),-\tan ^2\left (\frac {1}{2} (e+f x)\right )\right )\right ) \tan ^2\left (\frac {1}{2} (e+f x)\right )\right )}{f \left (45 \operatorname {AppellF1}\left (\frac {1}{2},m,1,\frac {3}{2},\tan ^2\left (\frac {1}{2} (e+f x)\right ),-\tan ^2\left (\frac {1}{2} (e+f x)\right )\right )^2 \cos ^2\left (\frac {1}{2} (e+f x)\right ) (1+2 m-2 m \cos (e+f x)+\cos (2 (e+f x)))+6 \operatorname {AppellF1}\left (\frac {1}{2},m,1,\frac {3}{2},\tan ^2\left (\frac {1}{2} (e+f x)\right ),-\tan ^2\left (\frac {1}{2} (e+f x)\right )\right ) \sin ^2\left (\frac {1}{2} (e+f x)\right ) \left (-5 \operatorname {AppellF1}\left (\frac {3}{2},m,2,\frac {5}{2},\tan ^2\left (\frac {1}{2} (e+f x)\right ),-\tan ^2\left (\frac {1}{2} (e+f x)\right )\right ) (1+2 m-2 (2+m) \cos (e+f x)+\cos (2 (e+f x)))+5 m \operatorname {AppellF1}\left (\frac {3}{2},1+m,1,\frac {5}{2},\tan ^2\left (\frac {1}{2} (e+f x)\right ),-\tan ^2\left (\frac {1}{2} (e+f x)\right )\right ) (1+2 m-2 (2+m) \cos (e+f x)+\cos (2 (e+f x)))-48 \left (2 \operatorname {AppellF1}\left (\frac {5}{2},m,3,\frac {7}{2},\tan ^2\left (\frac {1}{2} (e+f x)\right ),-\tan ^2\left (\frac {1}{2} (e+f x)\right )\right )-2 m \operatorname {AppellF1}\left (\frac {5}{2},1+m,2,\frac {7}{2},\tan ^2\left (\frac {1}{2} (e+f x)\right ),-\tan ^2\left (\frac {1}{2} (e+f x)\right )\right )+m (1+m) \operatorname {AppellF1}\left (\frac {5}{2},2+m,1,\frac {7}{2},\tan ^2\left (\frac {1}{2} (e+f x)\right ),-\tan ^2\left (\frac {1}{2} (e+f x)\right )\right )\right ) \cot (e+f x) \csc (e+f x) \sin ^4\left (\frac {1}{2} (e+f x)\right )\right )+40 \left (\operatorname {AppellF1}\left (\frac {3}{2},m,2,\frac {5}{2},\tan ^2\left (\frac {1}{2} (e+f x)\right ),-\tan ^2\left (\frac {1}{2} (e+f x)\right )\right )-m \operatorname {AppellF1}\left (\frac {3}{2},1+m,1,\frac {5}{2},\tan ^2\left (\frac {1}{2} (e+f x)\right ),-\tan ^2\left (\frac {1}{2} (e+f x)\right )\right )\right )^2 \cos (e+f x) \sin ^2\left (\frac {1}{2} (e+f x)\right ) \tan ^2\left (\frac {1}{2} (e+f x)\right )\right )} \]
[In]
[Out]
\[\int \left (a +a \sec \left (f x +e \right )\right )^{m}d x\]
[In]
[Out]
\[ \int (a+a \sec (e+f x))^m \, dx=\int { {\left (a \sec \left (f x + e\right ) + a\right )}^{m} \,d x } \]
[In]
[Out]
\[ \int (a+a \sec (e+f x))^m \, dx=\int \left (a \sec {\left (e + f x \right )} + a\right )^{m}\, dx \]
[In]
[Out]
\[ \int (a+a \sec (e+f x))^m \, dx=\int { {\left (a \sec \left (f x + e\right ) + a\right )}^{m} \,d x } \]
[In]
[Out]
\[ \int (a+a \sec (e+f x))^m \, dx=\int { {\left (a \sec \left (f x + e\right ) + a\right )}^{m} \,d x } \]
[In]
[Out]
Timed out. \[ \int (a+a \sec (e+f x))^m \, dx=\int {\left (a+\frac {a}{\cos \left (e+f\,x\right )}\right )}^m \,d x \]
[In]
[Out]